<!-- 百科 -->
<div class="container encyclopedias">
	<div class="search">
		<?php $objForm = $this->beginWidget('CActiveForm', array('id' => 'SubmitForm', 'method' => 'get', 'action' => yii::app()->createUrl('/front/index/meilishuo'))); ?>

			<span><label>标题：</label><?php echo $objForm->textField($model,'title',array()) ?></span>
			<span><label>内容：</label><?php echo $objForm->textField($model,'content',array()) ?></span>
			<button>搜索</button>
		<?php $this->endWidget(); ?>
	</div>

	<div class="content">
		<div class="content_left left">
			<?php  foreach($models as $data){ ?>
				<div data-id="<?php echo $data->id ?>" class="content_detail">
					<div class="name_time">
						<am class="name">
							<?php if($data->admin_username){echo $data->admin_username;}else{echo $data->username;} ?>
						</am>
						<span class="time">
							<?php  echo date('m-d H:i:s', $data->createtime)  ?>
						</span>
						<div class="clear"></div>
					</div>
					<div class="title">
						<div class="left"><img src="<?php echo Yii::app()->theme->baseUrl; ?>/assets/images/besttitle_b.jpg"></div>
						<h3 class="left"><a href="<?php echo $this->createUrl('/front/index/articlesDetail', array('id' => $data->id))  ?>"><?php  echo $data->title ?></a></h3>
						<div class="clear"></div>
					</div>
					<div class="content_d"><?php  echo $data->content; ?></div>	
						<div class="share-box" style="display: block;">
			                <div class="share">
			                    <div class="title pull-left">分享到：</div>
			                    <div style="margin-top:10px" class="bdsharebuttonbox pull-left" data-tag="share_2" data-text="sh2" id="share_2">
			                        <a class="share_weixin share_icon" target="_blank" data-cmd="weixin" _hover-ignore="1"></a>
									<a class="share_sqq share_icon" target="_blank" data-cmd="sqq" href="http://connect.qq.com/widget/shareqq/index.html?url=http://www.1zw.com/g81874.html&amp;title=鲜花饼云南特产8枚装&amp;desc=【1折网官网】全场包邮1折起，每天早上准时十点特价新品等你抢！&amp;pics=http://gw.alicdn.com/bao/uploaded/i3/TB1SSOrGXXXXXcrapXXXXXXXXXX_!!0-item_pic.jpg_300x300.jpg"></a>
									<a class="share_tsina share_icon" target="_blank" data-cmd="tsina" href="http://service.weibo.com/share/share.php?url=http://www.1zw.com/g81874.html&amp;title=【1折网官网】全场包邮1折起，每天早上准时十点特价新品等你抢！&amp;appkey=1343713053&amp;searchPic=false&amp;pic=http://gw.alicdn.com/bao/uploaded/i3/TB1SSOrGXXXXXcrapXXXXXXXXXX_!!0-item_pic.jpg_300x300.jpg"></a>
									<a class="share_qzone share_icon" target="_blank" data-cmd="qzone" href="http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url=http://www.1zw.com/g81874.html&amp;title=鲜花饼云南特产8枚装&amp;desc=【1折网官网】全场包邮1折起，每天早上准时十点特价新品等你抢！&amp;pics=http://gw.alicdn.com/bao/uploaded/i3/TB1SSOrGXXXXXcrapXXXXXXXXXX_!!0-item_pic.jpg_300x300.jpg"></a>
			                    </div>

			                    <div class="clearfix"></div>
			                </div>
						</div>							
				</div>

			<?php  } ?>
<div class="paging_panel c_f">
	<div class="pageNav">
	        <?php
	        $this->widget('CLinkPager', array(
	            'header' => "",
	            'firstPageLabel' => '首页',
	            'lastPageLabel' => '末页',
	            'prevPageLabel' => '上一页',
	            'nextPageLabel' => '下一页',
	            'pages' => $pages,
	            'footer' => "<span>共<em>{$pages->pageCount}</em>页</span>",
	            'maxButtonCount' => 20
	                )
	        );
	        ?>


	</div>
	</div>

		</div>

		<div class="content_right right"></div>


		<div class="clear"></div>
	</div>

	


</div>


<script type="text/javascript">
	RECORD_ID = '0';


	$(function(){
		$(".content_detail").mouseover(function(event) {
			RECORD_ID = $(this).data('id');
		});		
	})






    window._bd_share_config = {

        common: {
            bdText: '【1折网官网】淘牛品U站官网1zw taoniupin 妈咪街 1折特卖网 天天特价 9.9包邮秒杀 9块9 九块九包邮 九块邮',
            bdDesc: '【1折网官网】淘牛品U站官网1zw taoniupin 妈咪街 1折特卖网 天天特价 9.9包邮秒杀 9块9 九块九包邮 九块邮',
            bdUrl: 'http://www.1zw.com',
            bdPic: '',
            onBeforeClick: function(cmd, config) {
                if (RECORD_ID !== '0') {
                	var obj = $("[data-id='"+RECORD_ID+"']").eq(0);
                    var share_text = obj.find('.title .left a').html();
                    var share_desc = obj.find('.content_d').html();
                    console.log(share_desc);
                    //var share_pic = $("thumb_" + RECORD_ID).attr('src');
                    var share_url = 'http://www.mamijie.com' + obj.find('.title .left a').attr('href');
                    return {
                        bdText: share_text,
                        bdDesc: share_desc,
                        bdUrl: share_url
                    };
                }

            }
        },
        share: [{
            "bdSize": 16
        }]
    };
    with(document)
        //$.getScript('http://bdimg.share.baidu.com/static/api/js/share.js?cdnversion=' + ~(-new Date()));
    0[(getElementsByTagName('head')[0] || body).appendChild(createElement('script')).src = 'http://bdimg.share.baidu.com/static/api/js/share.js?cdnversion=' + ~(-new Date() / 36e5)];
</script>